#include<bits/stdc++.h>
using namespace std;
typedef long long ll;

const double PI = acos(-1);

struct Complex {
    double x, y;
    Complex(double xx = 0, double yy = 0) : x(xx), y(yy) {}
    Complex operator + (const Complex& b) const { return Complex(x + b.x, y + b.y); }
    Complex operator - (const Complex& b) const { return Complex(x - b.x, y - b.y); }
    Complex operator * (const Complex& b) const { return Complex(x * b.x - y * b.y, x * b.y + y * b.x); }
};

void FFT(vector<Complex>& a, vector<int>& r, int limit, int type) {
    for(int i = 0; i < limit; i++) {
        if(i < r[i]) swap(a[i], a[r[i]]);
    }
    for(int mid = 1; mid < limit; mid <<= 1) {
        Complex wn(cos(PI / mid), type * sin(PI / mid));
        for(int R = mid << 1, j = 0; j < limit; j += R) {
            Complex w(1, 0);
            for(int k = 0; k < mid; k++, w = w * wn) {
                Complex x = a[j + k];
                Complex y = w * a[j + k + mid]; 
                a[j + k] = x + y;
                a[j + k + mid] = x - y;
            }
        }
    }
    if(type == -1) {
        for(int i = 0; i < limit; i++) {
            a[i].x /= limit;
        }
    }
}

void solve() {
    string sa, sb;
    cin >> sa >> sb;
    ll n = sa.size(), m = sb.size();
    
    reverse(sa.begin(), sa.end());
    reverse(sb.begin(), sb.end());
    
    vector<Complex> a(n), b(m);
    for(int i = 0; i < n; i++) a[i].x = sa[i] - '0', a[i].y = 0;
    for(int i = 0; i < m; i++) b[i].x = sb[i] - '0', b[i].y = 0;

    ll limit = 1, l = 0;
    while(limit < n + m - 1) {
        limit <<= 1;
        l++;
    }
    
    a.resize(limit);
    b.resize(limit);
    vector<int> r(limit, 0);
    for(int i = 0; i < limit; i++) {
        r[i] = ((r[i >> 1] >> 1) | ((i & 1) << (l - 1)));
    }
    
    FFT(a, r, limit, 1);
    FFT(b, r, limit, 1);
    for(int i = 0; i < limit; i++) {
        a[i] = a[i] * b[i];
    }
    FFT(a, r, limit, -1);
    
    vector<int> res(limit+1);
    for(int i = 0; i < limit; i++) {
        res[i] = (int)(a[i].x + 0.5);
    }
    
    int carry = 0;
    for(int i = 0; i < limit; i++) {
        res[i] += carry;
        carry = res[i] / 10;
        res[i] %= 10;
    }
    if(carry!=0){
        res[limit]=carry;
    }

    int pos = limit;
    while(pos >= 0 && res[pos] == 0) pos--;
    
    if(pos < 0) cout << 0;
    else for(int i = pos; i >= 0; i--) cout << res[i];
    cout << endl;
}

int main() {
    ios::sync_with_stdio(0);
    cin.tie(0), cout.tie(0);
    int t = 1;
    // cin >> t;
    while(t--) {
        solve();
    }
    return 0;
}